﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Common;

namespace Ex08
{

    /// <summary>
    /// Problem?:Deffered Execution
    /// </summary>
    class Program
    {
        static void Main(string[] args)
        {
            var numbers = new List<int>();
            numbers.Add(1);

            IEnumerable<int> query = numbers.Select(n => n * 10);    // Build query

            numbers.Add(2);                    // Sneak in an extra element

            query.Dump("Notice both elements are returned in the result set");
            Console.ReadKey();
        }
    }
}
